<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>
<%@ Import Namespace="Sqwarea.Persistence" %>

<asp:Content ID="loginTitle" ContentPlaceHolderID="TitleContent" runat="server">Sqwarea: Welcome</asp:Content>

<asp:Content ID="loginContent" ContentPlaceHolderID="MainContent" runat="server">

    <h1>Welcome to sqwarea<%= (ViewData["User"] != null) ?
    " "+((User)ViewData["User"]).Nickname : "" %>!</h1>
    
    
 
<h2 style="clear:both;">Sqwarea is a massive multiplayer strategy game, on an infinite board. </h2>
<img src="./Content/Images/tuto1.png" alt="Sample illustration" class="right" />
<p>Extend your kingdom as wide as you can. <strong>Soldiers are automaticaly trained</strong> in your military academy.</p>
<p>The <strong>wider</strong> your kingdom is, the bigger your army can be, and the more troops you get.</p>
<p>Direct them to <strong>conquer</strong> new squares, but beware, for the infinite lands of Sqwarea are full of dangers. You will not always know what you are up against, since you only have detailed <strong>informations about the squares next</strong> to your kingdom. </p>
<img src="./Content/Images/tuto2.png" alt="Sample illustration" class="left" />
<p>Wether the square is <strong>red</strong> and owned by another human player, or <strong>grey</strong> and filled with wild barbarians, you will need to <strong>outnumber</strong> your oponents.</p>
<p>All your squares must be <strong>connected to your king</strong>, in order to ensure their allegiance. Therefore, do not forget to protect your territory.</p>
<p>The <strong>flags</strong> will inform you of incoming attacks so that you can send backup or remind you of attacks you ordered.</p>


    <p>
       Forge alliances, destroy empires, <strong>join the battle</strong> : <%= Html.ActionLink("register", "LogOn", "Account") %> now!
    </p>

    <h2 style="clear:both;">Best players</h2>
    <ol id="bestplayers" class="column-left">
        <%
            var i = 0;
            foreach (var king in (IEnumerable<King>)ViewData["BestKings"])
           { %>
           <% if (i == 10)
            {
        %>
    </ol>
    <ol class="column-right">            
         <%
            } %>
        <li class="best<%= i %>"><%= king.Nickname %> (<%= king.SquaresNumber %> squares)</li>
        <%
               i++;
           } %>
    </ol>
</asp:Content>